package cn.DesignModel.test;

import cn.DesignModel.factoryMethod.PizzaFactory;
import cn.DesignModel.factoryMethod.PizzaStore;

/**
 * @author: lizemin
 * @version: 1.0
 */
public class Demo {
    //这是一个main方法,是程序的入口
    public static void main(String[] args) {
        //点披萨中有创建披萨的方法
        PizzaStore store = new PizzaFactory();
        store.orderPizza("cheese");
        System.out.println("---------------");
        store.orderPizza("durian");

        PizzaFactory pizzaFactory = new PizzaFactory();
        //因为权限修饰符的封装，造成了这里无法绕开父类的orderPizza方法
//        pizzaFactory.createPizza()


    }
}
